]> dgit.raspbian.org Git - gnome-shell.git/commitdiff
messageTray: move the summary box pointer up when the keyboard shows
authorDan Winship <danw@gnome.org>
Fri, 9 Sep 2011 13:45:39 +0000 (09:45 -0400)
committerDan Winship <danw@gnome.org>
Fri, 23 Sep 2011 11:55:47 +0000 (07:55 -0400)
If the keyboard is shown when a summary boxpointer is visible (eg,
when opening a chat source), animate the boxpointer up with the tray.

https://bugzilla.gnome.org/show_bug.cgi?id=658603

js/ui/messageTray.js

index cf149ead8d104d02264378e145f15ba8738d9b7e..f0274872d913c12fa9cc3a365e0483484d6d231c 100644 (file)
@@ -1356,6 +1356,7 @@ MessageTray.prototype = {
         this._summaryBin.opacity = 0;
 
         this._summaryMotionId = 0;
+        this._trayMotionId = 0;
 
         this._summaryBoxPointer = new BoxPointer.BoxPointer(St.Side.BOTTOM,
                                                             { reactive: true,
@@ -2272,6 +2273,8 @@ MessageTray.prototype = {
         // _clickedSummaryItem.actor can change absolute position without changing allocation
         this._summaryMotionId = this._summary.connect('allocation-changed',
                                                       Lang.bind(this, this._adjustSummaryBoxPointerPosition));
+        this._trayMotionId = Main.layoutManager.trayBox.connect('notify::anchor-y',
+                                                                Lang.bind(this, this._adjustSummaryBoxPointerPosition));
 
         this._summaryBoxPointer.actor.opacity = 0;
         this._summaryBoxPointer.actor.show();
@@ -2303,8 +2306,10 @@ MessageTray.prototype = {
         if (this._clickedSummaryItemAllocationChangedId) {
             this._clickedSummaryItem.actor.disconnect(this._clickedSummaryItemAllocationChangedId);
             this._summary.disconnect(this._summaryMotionId);
+            Main.layoutManager.trayBox.disconnect(this._trayMotionId);
             this._clickedSummaryItemAllocationChangedId = 0;
             this._summaryMotionId = 0;
+            this._trayMotionId = 0;
         }
 
         if (this._clickedSummaryItem)